/**
 * Copyright &copy; 2012-2016 <a href="https://github.com/thinkgem/jeesite">JeeSite</a> All rights reserved.
 */
package com.thinkgem.jeesite.modules.cardrule.entity;

import com.thinkgem.jeesite.common.persistence.DataEntity;
import com.thinkgem.jeesite.modules.reader.entity.ReaderRoler;
import org.hibernate.validator.constraints.Length;

/**
 * 自助办卡种类Entity
 * @author zhangc
 * @version 2018-01-07
 */
public class LibraryCardRule extends DataEntity<LibraryCardRule>{
	
	private static final long serialVersionUID = 1L;
	private String name;		// 规则名称
	private String ruleCode;		// 规则编码
	private ReaderRoler readerRoler;		// 对应角色
	private String deposit;		// 卡押金
	private String def;		// 是否为默认角色
	
	public LibraryCardRule() {
		super();
	}

	public LibraryCardRule(String id){
		super(id);
	}

	@Length(min=1, max=50, message="规则名称长度必须介于 1 和 50 之间")
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}
	
	@Length(min=1, max=50, message="规则编码长度必须介于 1 和 50 之间")
	public String getRuleCode() {
		return ruleCode;
	}

	public void setRuleCode(String ruleCode) {
		this.ruleCode = ruleCode;
	}
	
	public ReaderRoler getReaderRoler() {
		return readerRoler;
	}

	public void setReaderRoler(ReaderRoler readerRoler) {
		this.readerRoler = readerRoler;
	}
	
	@Length(min=1, max=11, message="卡押金长度必须介于 1 和 11 之间")
	public String getDeposit() {
		return deposit;
	}

	public void setDeposit(String deposit) {
		this.deposit = deposit;
	}
	
	@Length(min=1, max=4, message="是否为默认角色长度必须介于 1 和 4 之间")
	public String getDef() {
		return def;
	}

	public void setDef(String def) {
		this.def = def;
	}
	
}